<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">

<title>My JSP 'login.jsp' starting page</title>

<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">

</head>

<body>
	This is login page.
	<br>
	<form action="./login/login" method="post">
		<div>
			用户名：<input type="Text" name="userid"><br>
			密&nbsp;码：<input type="text" name="password" /><br>
			验证码：<input  id="code" type="text" name="VerificationCode" onfocus="this.value='';"/>
        	<a >
        		<img alt="验证码" name="randImage" id="randImage" src="./login/getVerificationCode" width="70" height="25" align="middle" onclick="changeVerificationCode()"> 
        	</a><br> 
			<button type="submit">登陆</button>
			<button type="reset" style="margin-left: 100px">重置</button>
		</div>
	</form>
<script type="text/javascript">
	function changeVerificationCode(){
		alert(1);
		document.getElementById("randImage").src = "./login/getVerificationCode";
		alert(2);
	}
</script>
</body>
</html>
